//**********组织架构***********/;
import request from '@/utils/request.js';

/**
 * 保存
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * data 参数 
 *  createBy:'', //$column.comments 	类型:string 非必填
 *  createDate:'', //$column.comments 	类型:string 非必填
 *  deleted:'', //是否删除,0: 未删除 1: 删除  	类型:integer 非必填
 *  fullPinyin:'', //全拼 	类型:string 非必填
 *  id:'', //$column.comments 	类型:integer 非必填
 *  modifyBy:'', //$column.comments 	类型:string 非必填
 *  modifyDate:'', //$column.comments 	类型:string 非必填
 *  name:'', //组织名称 	类型:string 非必填
 *  parentId:'', //父节点id 	类型:integer 非必填
 *  parentIds:'', //父节点集合 	类型:string 非必填
 *  serialNum:'', //排序序号 	类型:integer 非必填
 *  simplicity:'', //简拼 	类型:string 非必填
 * @returns
 * ********
 */
export function postHmorg(data={}, config={}){
  return request({
    method: 'post',
    data,
    url: `/api/hmorg`,
    ...config,
  }) 
}

/**
 * 修改
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * data 参数 
 *  createBy:'', //$column.comments 	类型:string 非必填
 *  createDate:'', //$column.comments 	类型:string 非必填
 *  deleted:'', //是否删除,0: 未删除 1: 删除  	类型:integer 非必填
 *  fullPinyin:'', //全拼 	类型:string 非必填
 *  id:'', // 	类型:integer 非必填
 *  modifyBy:'', //$column.comments 	类型:string 非必填
 *  modifyDate:'', //$column.comments 	类型:string 非必填
 *  name:'', //组织名称 	类型:string 非必填
 *  parentId:'', //父节点id 	类型:integer 非必填
 *  parentIds:'', //父节点集合 	类型:string 非必填
 *  serialNum:'', //排序序号 	类型:integer 非必填
 *  simplicity:'', //简拼 	类型:string 非必填
 * @returns
 * ********
 */
export function putHmorg(data={}, config={}){
  return request({
    method: 'put',
    data,
    url: `/api/hmorg`,
    ...config,
  }) 
}

/**
 * 删除
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * params 参数 
 * id:'', //id 必填
 * @returns
 * ********
 */
export function deleteHmorg(params={}, config={}){
  return request({
    method: 'delete',
    params,
    url: `/api/hmorg`,
    ...config,
  }) 
}

/**
 * 组织树节点下移
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * data 参数 
 *  createBy:'', //$column.comments 	类型:string 非必填
 *  createDate:'', //$column.comments 	类型:string 非必填
 *  deleted:'', //是否删除,0: 未删除 1: 删除  	类型:integer 非必填
 *  fullPinyin:'', //全拼 	类型:string 非必填
 *  id:'', // 	类型:integer 非必填
 *  modifyBy:'', //$column.comments 	类型:string 非必填
 *  modifyDate:'', //$column.comments 	类型:string 非必填
 *  name:'', //组织名称 	类型:string 非必填
 *  parentId:'', //父节点id 	类型:integer 非必填
 *  parentIds:'', //父节点集合 	类型:string 非必填
 *  serialNum:'', //排序序号 	类型:integer 非必填
 *  simplicity:'', //简拼 	类型:string 非必填
 * @returns
 * ********
 */
export function putHmorgDown(data={}, config={}){
  return request({
    method: 'put',
    data,
    url: `/api/hmorg/down`,
    ...config,
  }) 
}

/**
 * 列表
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * ********
 * @returns
 * ********
 */
export function getHmorgList(config={}){
  return request({
    method: 'get',
    url: `/api/hmorg/list`,
    ...config,
  }) 
}

/**
 * 组织树节点上移
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * data 参数 
 *  createBy:'', //$column.comments 	类型:string 非必填
 *  createDate:'', //$column.comments 	类型:string 非必填
 *  deleted:'', //是否删除,0: 未删除 1: 删除  	类型:integer 非必填
 *  fullPinyin:'', //全拼 	类型:string 非必填
 *  id:'', // 	类型:integer 非必填
 *  modifyBy:'', //$column.comments 	类型:string 非必填
 *  modifyDate:'', //$column.comments 	类型:string 非必填
 *  name:'', //组织名称 	类型:string 非必填
 *  parentId:'', //父节点id 	类型:integer 非必填
 *  parentIds:'', //父节点集合 	类型:string 非必填
 *  serialNum:'', //排序序号 	类型:integer 非必填
 *  simplicity:'', //简拼 	类型:string 非必填
 * @returns
 * ********
 */
export function putHmorgUp(data={}, config={}){
  return request({
    method: 'put',
    data,
    url: `/api/hmorg/up`,
    ...config,
  }) 
}

/**
 * 重名检查
 * @doc http://hanma-lesscode.hc-iiot.com/swagger-ui.html#!/
 * params 参数 
 * id:'', //id 非必填
 * value:'', //value 必填
 * parentId:'', //parentId 非必填
 * @returns
 * ********
 */
export function getHmorgValidatefield(params={}, config={}){
  return request({
    method: 'get',
    params,
    url: `/api/hmorg/validate-field`,
    ...config,
  }) 
}